package DEEPERsource.DEEPERsource.source.corpus;

import java.util.ArrayList;
import java.util.ListIterator;

/**
 * Represents a Composite class of the Composite pattern.
 * Implenments the basic functionality for compound text objects - 
 * Corpus, Abstract.
 * @author tfayruzo
 *
 */
public abstract class CompositeText extends Text {
	
	protected ArrayList<Text> children = new ArrayList<Text>();

	/**
	 * Overloaded method from the parent class to 
	 * satisfy compound structure. 
	 */
	@Override
	public ListIterator<Text> iterator(){
		return children.listIterator();
	}
}
